<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>
<form action="http://www.baidu.com/s">
    <input name="wd" />
    <input type="submit"
           value="百度一下"
           title="请您输入搜索词！"
           disabled style="cursor:not-allowed"  />

</form>
</body>

<script src="https://ss0.bdstatic.com/5aV1bjqh_Q23odCf/static/superman/js/lib/jquery-1.10.2_d88366fd.js"></script>
<script>
    var isOk = false;

  $("form").submit(
      function(){
          return isOk;
      }
  );
  $("[name=wd]").keyup(
      function(){
          var wd = $(this).val().trim();
          if(wd.length>0){
              $(this).next().removeAttr("disabled")
                  .css("cursor","").removeAttr("title");
              isOk = true;
          }else{
              $(this).next().attr("disabled","disabled")
                  .css("cursor","not-allowed")
                  .attr("title","请您输入搜索词！");
              isOk = false;
          }
      }
  );

</script>
</html>